/**
 * 
 */
package org.jfarrell.classes;

import java.io.Serializable;
import java.awt.Point;
import javax.swing.ImageIcon;
import java.awt.Image;

/**
 * @author Jason Farrell
 * Utility class for transferring data to the Main Server from the GUI
 * 
 * TODO
 * Add serializable traits to the object
 *
 */
public class PointImage implements Serializable
{
	private ImageIcon m_theImage = null;
	
	// getter
	public Image getImage() {
		return this.m_theImage.getImage();
	}
	
	// setter
	public void setImage( Image i ) {
		this.m_theImage = new ImageIcon(i);		// this might only get the reference, make sure we are actually storing the object
	}
	
	private Point m_thePoint = null;
	
	// getter
	public Point getPoint() {
		return this.m_thePoint;
	}
	
	// setter
	public void setPoint( Point p ) {
		this.m_thePoint = p;	// same issue here
	}
	
	public PointImage(Image pImage, Point pPoint)
	{
		this.m_theImage = new ImageIcon( pImage );
		this.m_thePoint = pPoint;
	}
}

